﻿@model Bidder

@{
    Layout = "~/Views/Shared/_EmptyLayout.cshtml";
    ViewBag.Title = "เพิ่ม ผู้ขาย [BD]";
    ViewBag.Descr = "เพิ่ม ผู้ขาย";
}

@using (Html.BeginForm("Create", "Bidder", FormMethod.Post, new { @class = "form-horizontal" }))
{
    @Html.AntiForgeryToken()

    <div class="block-button-menu-above">
        @Html.ActionLink("กลับไปหน้าแสดงข้อมูลทั้งหมด", "Index", new { BidId = Model.BidId, PrId = Model.PrId }, new { @class = "btn btn-gray button-standard-width btn-small", role="button" })
        @*@Html.ButtonViewAll(false, "Index", .ToString())*@
        @Html.ButtonSubmit()
    </div>
    
    <div class="alert-error">
    @Html.ValidationSummary()
    </div>
    @Html.Partial("_EditorForm")

}

@section scripts
{
    <script>

        $("form").submit(function (e) {
            e.preventDefault();
            var currentForm = this;
            bootbox.confirm(function (result) {
                if (result) {
                    currentForm.submit();
                }
            });
        });

        $(function () {
        });
    </script>
}